from django.conf.urls import url
from django.urls import path, re_path, include
from rest_framework.routers import DefaultRouter

from app01 import views

# goods_list = views.DRFViewSet.as_view({
#     'get':'list',
# })
router = DefaultRouter()
router.register(r'goods',views.GoodsView1)


urlpatterns = [
    path('login', views.AuthView.as_view(),name='login'),
    path('goods_django', views.djangoForm.as_view(),name='goods_django'),
    path('goods_drf', views.DRFView.as_view(),name='goods_drf'),
    path('goods_drf_many', views.DRFManyView.as_view(),name='goods_drf_many'),
    path('goods_drf_many_many', views.DRFManyManyView.as_view(),name='goods_drf_many_many'),
    path('goods_drf_many_many2', views.DRFManyMany2View.as_view(),name='goods_drf_many_many2'),
    re_path(r'', include(router.urls),name='goods'),
    # path('bbb', views.DRFViewSet.as_view(),name='bbb'),
    # url(r'', include(router.urls),name='zidong'),
]
